import { Outlet } from "react-router-dom";
import { Layout } from "antd";
import LayoutMenu from "./components/Menu";
import LayoutHeader from "./components/Header";
import "./index.less";

const LayoutIndex = (props: any) => {
  const { Sider, Content } = Layout;
  return (
    <section className='container'>
      <Sider
        trigger={null}
        collapsed={props.isCollapse}
        width={220}
        theme='dark'
      >
        <LayoutMenu></LayoutMenu>
      </Sider>
      <Layout>
        <LayoutHeader></LayoutHeader>
        <Content>
          <Outlet></Outlet>
        </Content>
      </Layout>
    </section>
  );
};

export default LayoutIndex;
